home *** CD-ROM | disk | FTP | other *** search
/ TPUG - Toronto PET Users Group / TPUG Users Group CD / TPUG Users Group CD.iso / C64 / G-Games / (c)gc.d64 / driver.c (.txt) < prev    next >
Commodore BASIC  |  2007-02-04  |  2KB  |  72 lines

  1. 1 PG$=" 6 4 - D R I V E R ":AU$="DONT HIT THE SIDES !":JF=1
  2. 2 POKE53280,0:POKE53281,0
  3. 90 GOTO62000
  4. 100 DIML$(9),L(3),B(25),P%(1000):GOSUB1000:POKE53280,0:POKE53281,0
  5. 110 POKEVIC,0:POKEVIC+23,0:POKEVIC+29,0:POKEVIC+27,000
  6. 115 N=19:PRINT"[147]":V=-46:W=0
  7. 120 Q=35:M=2:K=162:U=0:I=0:B=0
  8. 121 POKE2040,13:POKE53287,8
  9. 125 POKEVIC,K:POKEVIC+1,160
  10. 128 L$(1)="[169]    /    [146][169]":L$(3)="[157][223]    [205]   [223]":L$(2)="    [167]     "
  11. 129 L$(4)="[169]   /   [146][169]":L$(6)="[157][223]   [205]   [223]":L$(5)="   [167]    "
  12. 130 L$(7)="[169]  /  [146][169]":L$(9)="[157][223]  [205]  [223]":L$(8)="  [167]   "
  13. 132 PRINT"[147]":FORN=1TO25:PRINTTAB(11)L$(2):NEXT:PRINT"";:N=11
  14. 133 POKEVIC+21,1
  15. 135 L(1)=-1:L(2)=0:L(3)=1
  16. 140 PRINTTAB(N)L$(M+I)
  17. 142 U=U+1:IFU=110THEN300
  18. 145 POKE53264,SGN(KAND256):POKE53248,KAND255
  19. 155 Q=Q+1:A=PEEK(56320):IFA=123THENK=K-8
  20. 156 IFPEEK(1622+K/8)=32THEN400
  21. 157 GETA$:IFA$="Q"THEN600
  22. 160 IFA=119THENK=K+8
  23. 175 IFRND(1)>.7THENM2=M:M=INT(RND(1)*3)+1
  24. 185 N1=N+L(M)
  25. 190 IFN1>27ORN1<4THENN1=N:M=2
  26. 195 N=N1:GOTO140
  27. 200 IFW=0THENW=1:V=-22:GOTO210
  28. 205 W=0:V=-46
  29. 210 POKE53287,W:POKE53287,W:RETURN
  30. 300 IFBTHEN500
  31. 302 IFI=6THENB=B+1:PRINT"";:U=100:GOTO145
  32. 305 IFM<>2THENU=109:GOTO145
  33. 310 N=N+1:U=0:M=2:I=I+3
  34. 320 GOTO145
  35. 400 FORN=1TO30:POKE53280,1:FORT=1TO10:NEXT:POKE53280,0:NEXT
  36. 410 POKE53269,0:PRINT"[147]YOU CRASHED!":GOTO545
  37. 500 FORN=1TO1000:NEXT:POKE53248+21,0
  38. 505 PRINT"[147]YOU FINISHED THE COURSE!"
  39. 545 PRINT:GOSUB9100 :PRINT"";:IF YNTHEN120
  40. 546 PRINT"[147]":END
  41. 550 TM=TI+10
  42. 560 IFTM>TITHEN560
  43. 570 RETURN
  44. 600 PRINT"[147]THANKS FOR PLAYING!":POKE53248,0:END
  45. 900 PRINTPEEK(56320):GOTO900
  46. 1000 READA:FORN=64*13TO64*14-3:READA:POKEN,A:NEXT:RETURN
  47. 9100 NO=0
  48. 9110 TM=0:SW=1
  49. 9115 PRINT"PLAY AGAIN? [151]YES NO[145]"
  50. 9120 IF TI<TMTHEN9150
  51. 9130 PRINTTAB(12+NO*4);MID$("[151]",SW,1);MID$("YESNO[160]",3*NO+1,3);"[145]"
  52. 9140 SW=3-SW:TM=TI+15
  53. 9150 JD=PEEK(JS)AND31:JB=(JD<16):JD=JDAND15
  54. 9160 IFJBANDJD=15THENYN=(NO=0):RETURN
  55. 9170 IF(JDAND8)=0ANDNO=0THENNO=1:GOTO9115
  56. 9180 IF(JDAND4)=0ANDNO=1THENNO=0:GOTO9115
  57. 9190 GOTO9120
  58. 50000 DATA62,0,0,0,71,255,226,239,60,247,254,24,127,253,255,191,237,193,183
  59. 50001 DATA237,128,183,205,255,243,13,128,112,15,255,240,15,255,240,15,255,240
  60. 50002 DATA15,255,240,239,255,240,255,255,247,255,255,255,255,255,255,247,255
  61. 50003 DATA127,243,190,239,1,255,128,0,127
  62. 61000 CRT=1024:VIC=53248:WD=40:CR$=CHR$(13):SID=54272:JS=56320:CM=55296
  63. 61010 QL=214:QI=254:RETURN
  64. 62000 GOSUB61000:POKEVIC+23,0:POKEVIC+33,0:LN=LEN(PG$):TB=(40-LN)/2
  65. 62010 PRINT"[147][158]"TAB(TB)LEFT$("                     ",LN)
  66. 62020 PRINT""TAB(TB)PG$:PRINT""TAB(TB)LEFT$("                     ",LN)
  67. 62030 PRINT""TAB((40-LEN(AU$))/2)AU$
  68. 62040 MS$="PRESS KEY TO BEGIN"
  69. 62060 PRINT"[159]"TAB(TB)MS$:PRINT"[159]         "
  70. 62070 GETIN$:IFIN$=""THEN62070
  71. 62080 GOTO 100
  72.